package com.margo.project.netty.http;

import io.netty.bootstrap.ServerBootstrap;
import io.netty.channel.EventLoopGroup;
import io.netty.channel.nio.NioEventLoopGroup;
import io.netty.channel.socket.nio.NioServerSocketChannel;

public class MargoHttpService {
	public static void main(String[] args) throws InterruptedException {
		EventLoopGroup boosWork = new NioEventLoopGroup(1);
		EventLoopGroup work = new NioEventLoopGroup();
		ServerBootstrap bootstrap = new ServerBootstrap();
		bootstrap.group(boosWork, work).channel(NioServerSocketChannel.class).handler(new MargoServiceChannelHandler())
				.childHandler(new MargoChannelInitializer()).bind("localhost", 8080).sync();

	}
}
